<?php


namespace app\common\model;


use think\Model;

class FootballMatchAnchorModel extends Model
{
    public function anchor(){
        return $this->hasOne(UserModel::class,'id','anchorid')->with(['profile','live'])->field("id, account, nick_name, avatar, is_anchor, diamond, sharing_ratio, online_status");
    }

    public function match(){
        return $this->hasOne('FootballMatchModel','id','matchid')->with(['matchevent','hometeam','awayteam']);
    }
}